<%--
  Created by IntelliJ IDEA.
  User: 13585
  Date: 2020/12/23
  Time: 21:20
  To change this template use File | Settings | File Templates.
--%>
<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>


<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="utf-8">
    <link rel="stylesheet" href="${pageContext.request.getContextPath()}/back/layui/css/layui.css">
    <link rel="stylesheet" href="${pageContext.request.getContextPath()}/back/css/index.css">
</head>
<body>
<div id="addmeeting">
    <form class="layui-form" action="addMeeting">
        <c:if test="${!empty msg}">
            <div id="prompt">
                <span>${msg}</span>
                <button class="determine" onclick="changeDis()">确定</button>
            </div>
        </c:if>
        <script>
            function changeDis() {
                let msg = document.getElementById("prompt");
                msg.style.display = "none";
            }
        </script>
        <div class="layui-form-item">
            <label class="layui-form-label">会议室名称</label>
            <div class="layui-input-block">
                <input type="text" name="name" required  lay-verify="required" placeholder="请填写会议室名称" autocomplete="off" class="layui-input">
            </div>
        </div>
        <div class="layui-form-item">
            <label class="layui-form-label">座位数</label>
            <div class="layui-input-block">
                <input type="text" name="num" required  lay-verify="required" placeholder="请填写座位数" autocomplete="off" class="layui-input">
            </div>
        </div>
        <div class="layui-form-item">
            <label class="layui-form-label">是否可用</label>
            <div class="layui-input-block">
                <select name="status" lay-verify="">
                    <option value="可使用">可使用</option>
                    <option value="可使用">不可使用</option>
                </select>
            </div>
        </div>
        <div class="layui-form-item">
            <label class="layui-form-label">地址</label>
            <div class="layui-input-block">
                <input type="text" name="address" required  lay-verify="required" placeholder="请填写地址" autocomplete="off" class="layui-input">
            </div>
        </div>
        <div class="layui-form-item">
            <label class="layui-form-label">备注</label>
            <div class="layui-input-block">
                <input type="text" name="remarks" required  lay-verify="required" placeholder="请简短描述一下会议室信息" autocomplete="off" class="layui-input">
            </div>
        </div>
        <div class="layui-form-item">
            <div class="layui-input-block">
                <button class="layui-btn" lay-submit lay-filter="formDemo">立即提交</button>
                <button type="reset" class="layui-btn layui-btn-primary">重置</button>
            </div>
        </div>
    </form>
</div>
<script type="text/javascript" src="${pageContext.request.getContextPath()}/back/layui/layui.js"></script>
<script>
    layui.use('form', function(){
        var form = layui.form;
        form.render();
    });
</script>

<%--<script>
        //Demo
        layui.use('form', function(){
            var form = layui.form;

            //监听提交
            form.on('submit(formDemo)', function(data){
                layer.msg(JSON.stringify(data.field));
                return false;
            });
        });
    </script>--%>
</body>
</html>
